package com.chance.cc.crawler.prod.command.trigger.domain.vm.xcar.supplement;

import com.chance.cc.crawler.core.CrawlerJob;
import com.chance.cc.crawler.meta.core.bean.CrawlerMetaConstant;
import com.chance.cc.crawler.prod.command.job.domain.vm.xcar.XCarAutoCommonCrawlerSchedulerJob;
import com.chance.cc.crawler.prod.command.job.domain.vm.xcar.supplement.XcarForumReleaseSimpleCrawlerSchedulerJob;
import com.chance.cc.crawler.prod.command.trigger.CommonCrawlerSchedulerTrigger;

/**
 * @author lt
 * @version 1.0
 * @date 2021-05-18 14:27:17
 * @email okprog@sina.com
 */
public class XCarSimpleCrawlerScheduleTrigger extends CommonCrawlerSchedulerTrigger {
    public static void main(String[] args) {
      //  publishXCarCrawlerScheduleTriggerInfo(XCarPriseSimpleCrawlerSchedulerJob.xcarCwalerJob());
//        publishXCarCrawlerScheduleTriggerInfo(XcarForumReplyTraceSupplementCrawlerScheduleJob.xcarCwalerJob());
        publishXCarCrawlerScheduleTriggerInfo(XcarForumReleaseSimpleCrawlerSchedulerJob.xcarCwalerJob());
        //publishXCarCrawlerScheduleTriggerInfo(XcarNewsSimpleCrawlerScheduleJob.xcarCwalerJob());
        //四垂媒采集任务 文章和视频
        //publishXCarCrawlerScheduleTriggerInfo(XcarSimpleRedisToRunCrawlerScheduleJob.xcarScheduleCarHomeArticle());
        //publishXCarCrawlerScheduleTriggerInfo(XcarForumRealTimeCrawlerScheduleJob.xcarCwalerJob());
    }

    /**
     * 发布汽车之家临时采集trigger info

     */
    public static void publishXCarCrawlerScheduleTriggerInfo(CrawlerJob crawlerJob){

        metaServiceCommand_17.addOrUpdateScheduleCrawlerTrigger(
                crawlerJob.generateCrawlerKey(),
                crawlerJob.generateCrawlerTriggerKey(),
                XCarAutoCommonCrawlerSchedulerJob.domain,
                CrawlerMetaConstant.ScheduleJobTrigger_Simple,
                "",
                "爱卡临时采集任务执行，单次执行"
        );
    }
}
